﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Company.Hardware.Camera
{
    public interface ICamera
    {
        event Action<Photo> OnGrabbed;


        /// <summary>
        /// 表示相机是否初始化完成
        /// </summary>
        bool Initialized { get; }

        /// <summary>
        /// 初始化相机
        /// </summary>
        /// <returns></returns>
        bool Init(ICameraConfigProvider provider);

        /// <summary>
        /// 相机拍照
        /// </summary>
        /// <returns></returns>
        bool Trigger();

        /// <summary>
        /// 关闭相机
        /// </summary>
        void Close();
    }
}
